package com.walle.common.exceptions;

public class BaseException extends RuntimeException {
    private static final long serialVersionUID = 8070270929873683334L;

    /**
     * 具体异常码
     */
    protected int code;

    public BaseException(int code, String msgFormat, Object... args) {
        super(String.format(msgFormat, args));
        this.code = code;
        //this.message = String.format(msgFormat, args);
    }


    public BaseException(String message) {
        super(message);
    }
    public BaseException(String message, Throwable cause) {
        super(message, cause);
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }
}

